class Settings:
    """设置类"""
    def __init__(self):
        """游戏初始化设置"""
        self.SCREEN_WIDTH = 1200
        self.SCREEN_HEIGHT = 800
        self.screen_width = self.SCREEN_WIDTH
        self.screen_height = self.SCREEN_HEIGHT
        self.full_screen = False
        self.bg_color = (255, 255, 255)
        self.stop_time = 0.5
        self.font = 'calibri'
        self.font_size = 20
        self.big_font_size = 100

        # 飞船设置
        self.ship_limit = 10

        # 子弹设置
        self.bullets_allowed = 3
        self.bullet_width = 3
        self.bullet_height = 10
        self.bullet_color = (60, 60, 60)
        self.bullet_type = True  # True为普通子弹
        self.bullet_shooting_speed = 30

        # 外星人设置
        self.fleet_drop_speed = 10
        self.alien_points = 50
        self.alien_number = 1000
        self.score_scale = 1.5

        # 游戏节奏速度
        self.speedup_scale = 1.1

    def initialize_dynamic_settings(self):
        """动态设置"""
        self.ship_speed = 1.5
        self.bullet_speed = 3.0
        self.alien_speed = 1.0
        # fleet_direction为1则表示向右移，-1向左移
        self.fleet_direction = 1

    def increase_speed(self):
        """提高速度"""
        self.ship_speed *= self.speedup_scale
        self.bullet_speed *= self.speedup_scale
        self.alien_speed *= self.speedup_scale

        self.alien_points = int(self.alien_points * self.score_scale)
